package utils;

import java.util.Properties;

import librairies.liste.interfaces.IListeE;
import librairies.liste.list.ListeDCE;

public class PropertiesUtils 
{
	public static IListeE<String> getValueList(Properties pro, String key)
	{
		IListeE<String> list = new ListeDCE<String>();
		
		if(pro == null || key == null || key.length() == 0) return list;
		
		String value = pro.getProperty(key);
		if(value == null) return list;
		
		String[] tab = value.split(" ");
		if(tab == null || tab.length == 0) return list;
		
		for(int i = 0; i < tab.length; ++i)
		{
			list.add(tab[i]);
		}
		 return list;
	}
}
